<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ page contentType="text/html; charset=UTF-8" session="false" %>
<html>
<head>
    <title>Simple RabbitMQ Application</title>
</head>
<body>
<h1>Simple RabbitMQ Application</h1>

<h2>Publish a message</h2>



<h2>Get a message</h2>

<form id="testForm" name="testForm" method="post" >
    <input type="button" id="btnSubmit" value="发送" style="background-color: #2ebaef;width: 80px;height: 30px;outline: none;border: 0px;color: white"></input>
</form>

</body>
<script src="js/jquery-1.11.1.min.js"></script>
<script type="text/javascript">
    $(document).ready(function() {
        secondAJAX();
    });
    //每隔5秒轮询一次订单
    // setInterval(function () {
    //     secondAJAX();
    // },5000);
    function secondAJAX(){
        $.ajax({
            url:"/front/contact/get",
            type: "POST",
            cache: false,
            dataType: "json",
            success:function (data) {
                console.log(data)

            }
        });
    }
</script>
</html>